<?php

namespace app\common\validate\demo;

use think\Validate;

class DemoValidate extends Validate
{
    protected $rule = [
        'id' => 'require',
        'name' => 'require',
        'age' => 'require'
    ];

    protected $message = [
        'id.require' => 'id不能为空',
        'name.require' => 'name不能为空',
        'age.require' => 'age不能为空'
    ];

    protected $scene = [
        'getList' => ['name']
    ];
}